package com.rw;

import com.rw.pojo.FatherTest;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class Test {
    public static void main(String[] args) {
        ApplicationContext ac = new ClassPathXmlApplicationContext("applicationcontext.xml");
        FatherTest f = (FatherTest) ac.getBean("test");  //实例化操作
        FatherTest f1 = (FatherTest) ac.getBean("test");
        System.out.println(f1);
        System.out.println(f);
        f.test();
    }
}
